# Maintainer: Florian Pritz <bluewind@archlinux.org>

pkgname=perl-net-openssh
pkgver=0.84
pkgrel=1
pkgdesc='Perl SSH client package implemented on top of OpenSSH'
arch=(any)
license=(PerlArtistic GPL)
options=(!emptydirs)
depends=(perl)
url=https://metacpan.org/release/Net-OpenSSH
source=("https://cpan.metacpan.org/authors/id/S/SA/SALVA/Net-OpenSSH-$pkgver.tar.gz")
md5sums=(f6982bedfa711cf1c9fe72a8fd5578a6)
sha512sums=(eae50ddc609654432c77080dbfd1dbfd76a7651a1a4e85c0a0f01547b329761a6676faabec931a3b4ff5c74bfa4f529cf649249ad57e73305e67b33da891a555)
_ddir="Net-OpenSSH-$pkgver"

build()
(
  cd "$srcdir/$_ddir"
  export PERL_MM_USE_DEFAULT=1 PERL_AUTOINSTALL=--skipdeps
  unset PERL5LIB PERL_MM_OPT
  /usr/bin/perl Makefile.PL
  make
)

check()
(
  cd "$srcdir/$_ddir"
  export PERL_MM_USE_DEFAULT=1
  unset PERL5LIB
  make test
)

package()
(
  cd "$srcdir/$_ddir"
  make install INSTALLDIRS=vendor DESTDIR="$pkgdir"
)

# Local Variables:
# mode: shell-script
# sh-basic-offset: 2
# End:
# vim:set ts=2 sw=2 et:
